package edu.kaist.cs442.client.android.common.pushutil.send;

import android.content.Context;
import android.os.AsyncTask;
import edu.kaist.cs442.client.android.common.RestServices;
import edu.kaist.cs442.client.android.common.pushutil.register.TrackInstallation;
import edu.kaist.cs442.server.locationalpush.push.c2dm.MessageVO;

/**
 * Created by IntelliJ IDEA.
 * User: duyleekun
 * Date: 3/2/12
 * Time: 12:08 AM
 * To change this template use File | Settings | File Templates.
 */
public class Send extends AsyncTask<Context, Void, Void> {

	@Override
	protected Void doInBackground(Context... contexts) {
		MessageVO message = new MessageVO("0");
		message.put("tickerText", "Ticker ne` :D");
		message.put("contentTitle", "Title ne` :D");
		message.put("contentText", "Content ne` :D");
		RestServices.getPushSVC().sendTo(message, TrackInstallation.id(contexts[0]).toString());
		return null;
	}
}
